<template>
 <div class="inLogin">
  <div class="formInLogin">
   <div class="inpu">
    <div>
     <h2>西州医院一体化智慧中心</h2>
     <el-form :model="formData">
      <el-form-item>
       <el-input
        v-model="formData.account"
        placeholder="请输入您的用户名/邮箱"
       ></el-input>
      </el-form-item>
      <el-form-item>
       <el-input
        v-model="formData.password"
        type="password"
        placeholder="请输入您的密码"
       ></el-input>
      </el-form-item>
      <el-form-item>
       <el-button size="large" @click="Login">下一步</el-button>
      </el-form-item>
     </el-form>
    </div>
   </div>
   <div class="back-img"></div>
  </div>
 </div>
</template>

<script setup>
import { reactive } from 'vue'
import { inLogin } from '../../api/use'
// eslint-disable-next-line no-unused-vars
const formData = reactive({
 account: '',
 password: '',
})
function Login() {
 inLogin({
  account: formData.account,
  password: formData.password,
 }).then((res) => {
  console.log(res)
 })
}
</script>

<style lang="scss" scoped>
h2 {
 text-align: center;
}
.inLogin {
 height: 100%;
 width: 100%;
 background-color: white;
 display: flex;
 justify-content: center;
 align-items: center;
 .formInLogin {
  box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.5);
  border-radius: 20px;
  width: 50%;
  height: 50vh;
  display: flex;
  .back-img {
   border-radius: 0 20px 20px 0;
   width: 50%;
   height: 50vh;
   background: url('../../assets/imgs/wallhaven-o5129p.jpg') no-repeat center;
   background-size: cover;
  }
  .inpu {
   width: 50%;
   display: flex;
   border-radius: 20px;
   justify-content: center;
   align-items: center;
   background: #ffffff;
   height: 100%;
   box-sizing: border-box;
   div {
    width: 100%;
    .el-button {
     background-color: #9fceff;
     color: white;
     width: 100%;
    }
    .el-form {
     padding: 20px;
    }
    .el-input {
     height: 40px;
    }
   }
  }
 }
}
</style>
